<?php
/**
 * Created by PhpStorm.
 * User: zhan
 * Date: 2019/1/7  20:36
 */
namespace app\api\controller;
class Driver extends Base
{
    //检查权限作用域
    protected $beforeActionList = [
        'checkPrimaryScope' => [
            'except' => 'except'
        ]
    ];

    //审核司机申请
    public function check()
    {
        $result =  (new \app\api\logic\Driver())->check();
        return $this->ajaxReturn($result);
    }

    //我的司机
    public function index()
    {
        $result =  (new \app\api\logic\Driver())->index();
        return $this->ajaxReturn($result);
    }

    //司机详情
    public function info()
    {
        $result =  (new \app\api\logic\Driver())->info();
        return $this->ajaxReturn($result);
    }

    /*
    * 解绑司机
    */
    public function unbind()
    {
        $result =  (new \app\api\logic\Driver())->unbind();
        return $this->ajaxReturn($result);
    }

    /*
     * 商家插单(未用)
     */
    public function inclineOrder()
    {
        $result =  (new \app\api\logic\Driver())->inclineOrder();
        return $this->ajaxReturn($result);
    }

    //删除司机(未用)
    public function driverdel()
    {
        $result =  (new \app\api\logic\Driver())->driverdel();
        return $this->ajaxReturn($result);
    }

}